<?php

use Hyperf\Database\Schema\Schema;
use Hyperf\Database\Schema\Blueprint;
use Hyperf\Database\Migrations\Migration;

class CreateMaterialReportScoreTable extends Migration
{
    /**
     * Run the migrations.
     */
    public function up(): void
    {
        Schema::create('material_report_score', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->unsignedBigInteger('material_id',false)->default(0)->comment('材料id');
            $table->unsignedBigInteger('material_assign_id',false)->default(0)->comment('上报id');
            $table->unsignedBigInteger('material_project_id',false)->default(0)->comment('项目id');
            $table->unsignedInteger('score',false)->default(0)->comment('分值');
            $table->timestamps();
            $table->engine="InnoDb";
        });
    }

    /**
     * Reverse the migrations.
     */
    public function down(): void
    {
        Schema::dropIfExists('material_report_score');
    }
}
